package com.jackson.passjava.question.config;

import com.baomidou.mybatisplus.extension.plugins.PaginationInterceptor;
import com.jackson.passjava.common.handle.MyMetaObjectHandler;
import org.springframework.boot.autoconfigure.ImportAutoConfiguration;
import org.springframework.context.annotation.Bean;
import org.springframework.context.annotation.Configuration;
import org.springframework.transaction.annotation.EnableTransactionManagement;

/**
 * @application:
 * @author: LiYuhang
 * @Date: 2021/8/18 1:07
 * @version: 0.1
 */
@Configuration
@ImportAutoConfiguration(classes = MyMetaObjectHandler.class)
@EnableTransactionManagement
public class MybatisConfig {
    /**
     * 分页插件
     *
     * @return
     */
    @Bean
    public PaginationInterceptor paginationInterceptor() {
        return new PaginationInterceptor();
    }


}
